﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace Thor.Common
{
    public interface IMessageRepository : IRepository
    {
        /// <summary>
        /// Inserts a message into the repository.
        /// </summary>
        /// <param name="message"></param>
        void Insert(Message message);
        
        /// <summary>
        /// Retrieves a message from the repository.
        /// </summary>
        /// <returns></returns>
        Message Fetch();

        /// <summary>
        /// Peeks a message from the repository.
        /// </summary>
        /// <returns></returns>
        Message Peek();

        /// <summary>
        /// Deletes a message from the repository.
        /// </summary>
        /// <param name="message"></param>
        void Delete(Message message);

        /// <summary>
        /// Deletes all messages from the repository.
        /// </summary>
        void Clear();
    }
}
